// 引入Service和请求头ServiceName
import { Service, ServiceName } from '@/network/http.js'
import store from '@/store/index.js' // 引入store

const api = {
  /**
   * 新增
   */
  insert (params) {
    store.commit('changeStatus', true)
    return Service.post(
      `/${ServiceName}/api/external/workPlan/addTransportPlan`, params
    )
  },
  /**
   * 查询主列表
   */
  queryPort (params) {
    return Service.get(
      `/${ServiceName}/api/external/workPlan/queryTransportPlan`, {params}
    )
  },
  /**
   * 删除
   */
  deletePort (params) {
    return Service.delete(
      `/${ServiceName}/api/external/workPlan/deleteTransportPlan?id=${params}`
    )
  },
}
export default api